#include<bits/stdc++.h> 
#define  int long long 
#define endl '\n'
using namespace std;


int n, k, ans;


void solve()
{
    cin >> n>>k;
    if(n>=4300||n<0){
      cout<<"NO"<<endl; 
      return ;
	}
	if(k<1||k>2){
		cout<<"NO"<<endl;
		return;
	}
    if(k==1){
    	if(n>=1600&&n<=2999)cout<<"Yes"<<endl;
    	else cout<<"No"<<endl;
	}
	else if(k==2){
		if(n>=1200&&n<=2399)cout<<"Yes"<<endl;
		else cout<<"No"<<endl;
	}
	return ; 
}

signed main(){
    ios::sync_with_stdio(0), cin.tie(0), cout.tie(0);

    int t = 1;

    //cin >> t;

    while (t--) {

        solve();

    }
    return 0;
}
